

public class GetTid {
	// use JNI to get the java thread id.
	static {
		System.loadLibrary("gettid");
	}

	public native int gettid();// local method announcement

	/**
	 * use JNI to get the java thread id.
	 * @return java thread id.
	 */
	public int getThreadNr() {
		return gettid();
	}
}
